package com.hybao.security;

import java.util.Map;

public class SecurityContextHolder {
	private static final ThreadLocal<Map<String,Object>> contextHolder = new ThreadLocal<Map<String,Object>>();
	
	public static Map<String,Object> getContext() {
        return contextHolder.get();
    }
	
	public static void setContext(Map<String,Object> securityContext) {
        contextHolder.set(securityContext);
    }

    public static void clearContext() {
        contextHolder.remove();
    }
}
